#include "QQNavigationNode.h"

QQNavigationNode::QQNavigationNode(QObject* parent)
	: QObject(parent)
{
	mNodeIcon = QIcon();
	mNodeKey = QUuid::createUuid().toString().remove("{").remove("}").remove("-");
	mModelIndex = QModelIndex();
	mKeyPoints = 0;
	mIsVisible = false;
}

QQNavigationNode::~QQNavigationNode()
{
}

QString QQNavigationNode::getNodeKey() const
{
	return mNodeKey;
}

void QQNavigationNode::setNodeIcon(QIcon icon)
{
	mNodeIcon = icon;
}

QIcon QQNavigationNode::getNodeIcon() const
{
	return mNodeIcon;
}

void QQNavigationNode::setModelIndex(const QModelIndex& index)
{
	mModelIndex = index;
}

QModelIndex QQNavigationNode::getModelIndex() const
{
	return mModelIndex;
}

void QQNavigationNode::setKeyPoints(int keyPoints)
{
	mKeyPoints = keyPoints;
}

int QQNavigationNode::getKeyPoints() const
{
	return mKeyPoints;
}

void QQNavigationNode::setIsVisible(bool isVisible)
{
	mIsVisible = isVisible;
}

bool QQNavigationNode::getIsVisible() const
{
	return mIsVisible;
}

int QQNavigationNode::getRow() const
{
	if (!mModelIndex.isValid())
	{
		return -1;
	}
	return mModelIndex.row();
}
